From 5a3ebb486062ab4550a7233d147050e720f99069 Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Tue, 22 Jul 2014 02:53:06 +0200 Subject: [PATCH] stylecontext: Query style properties with correct state Now that widget paths are allowed to have a state, use that state when querying style properties. This uses a fast path in gtkcssprovider.c and that is great. --- gtk/gtkstylecontext.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gtk/gtkstylecontext.c b/gtk/gtkstylecontext.c index 8146819ba0..f7f3179321 100644 --- a/gtk/gtkstylecontext.c +++ b/gtk/gtkstylecontext.c @@ -2111,7 +2111,8 @@ _gtk_style_context_peek_style_property (GtkStyleContext *context, if (gtk_style_provider_get_style_property (GTK_STYLE_PROVIDER (priv->cascade), widget_path, - 0, pspec, &pcache->value)) + gtk_widget_path_iter_get_state (widget_path, -1), + pspec, &pcache->value)) { G_GNUC_BEGIN_IGNORE_DEPRECATIONS; -- 2.30.2